/*
 * XML Type:  CreditcardResponseMessageSetV1
 * Namespace: http://ofx.net/types/2003/04
 * Java type: net.ofx.types.x2003.x04.CreditcardResponseMessageSetV1
 *
 * Automatically generated - do not modify.
 */
package net.ofx.types.x2003.x04.impl;
/**
 * An XML CreditcardResponseMessageSetV1(@http://ofx.net/types/2003/04).
 *
 * This is a complex type.
 */
public class CreditcardResponseMessageSetV1Impl extends net.ofx.types.x2003.x04.impl.AbstractResponseMessageSetImpl implements net.ofx.types.x2003.x04.CreditcardResponseMessageSetV1
{
    
    public CreditcardResponseMessageSetV1Impl(org.apache.xmlbeans.SchemaType sType)
    {
        super(sType);
    }
    
    private static final javax.xml.namespace.QName CCSTMTTRNRS$0 = 
        new javax.xml.namespace.QName("", "CCSTMTTRNRS");
    private static final javax.xml.namespace.QName CCSTMTENDTRNRS$2 = 
        new javax.xml.namespace.QName("", "CCSTMTENDTRNRS");
    
    
    /**
     * Gets array of all "CCSTMTTRNRS" elements
     */
    public net.ofx.types.x2003.x04.CreditCardStatementTransactionResponse[] getCCSTMTTRNRSArray()
    {
        synchronized (monitor())
        {
            check_orphaned();
            java.util.List targetList = new java.util.ArrayList();
            get_store().find_all_element_users(CCSTMTTRNRS$0, targetList);
            net.ofx.types.x2003.x04.CreditCardStatementTransactionResponse[] result = new net.ofx.types.x2003.x04.CreditCardStatementTransactionResponse[targetList.size()];
            targetList.toArray(result);
            return result;
        }
    }
    
    /**
     * Gets ith "CCSTMTTRNRS" element
     */
    public net.ofx.types.x2003.x04.CreditCardStatementTransactionResponse getCCSTMTTRNRSArray(int i)
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.CreditCardStatementTransactionResponse target = null;
            target = (net.ofx.types.x2003.x04.CreditCardStatementTransactionResponse)get_store().find_element_user(CCSTMTTRNRS$0, i);
            if (target == null)
            {
                throw new IndexOutOfBoundsException();
            }
            return target;
        }
    }
    
    /**
     * Returns number of "CCSTMTTRNRS" element
     */
    public int sizeOfCCSTMTTRNRSArray()
    {
        synchronized (monitor())
        {
            check_orphaned();
            return get_store().count_elements(CCSTMTTRNRS$0);
        }
    }
    
    /**
     * Sets array of all "CCSTMTTRNRS" element
     */
    public void setCCSTMTTRNRSArray(net.ofx.types.x2003.x04.CreditCardStatementTransactionResponse[] ccstmttrnrsArray)
    {
        synchronized (monitor())
        {
            check_orphaned();
            arraySetterHelper(ccstmttrnrsArray, CCSTMTTRNRS$0);
        }
    }
    
    /**
     * Sets ith "CCSTMTTRNRS" element
     */
    public void setCCSTMTTRNRSArray(int i, net.ofx.types.x2003.x04.CreditCardStatementTransactionResponse ccstmttrnrs)
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.CreditCardStatementTransactionResponse target = null;
            target = (net.ofx.types.x2003.x04.CreditCardStatementTransactionResponse)get_store().find_element_user(CCSTMTTRNRS$0, i);
            if (target == null)
            {
                throw new IndexOutOfBoundsException();
            }
            target.set(ccstmttrnrs);
        }
    }
    
    /**
     * Inserts and returns a new empty value (as xml) as the ith "CCSTMTTRNRS" element
     */
    public net.ofx.types.x2003.x04.CreditCardStatementTransactionResponse insertNewCCSTMTTRNRS(int i)
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.CreditCardStatementTransactionResponse target = null;
            target = (net.ofx.types.x2003.x04.CreditCardStatementTransactionResponse)get_store().insert_element_user(CCSTMTTRNRS$0, i);
            return target;
        }
    }
    
    /**
     * Appends and returns a new empty value (as xml) as the last "CCSTMTTRNRS" element
     */
    public net.ofx.types.x2003.x04.CreditCardStatementTransactionResponse addNewCCSTMTTRNRS()
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.CreditCardStatementTransactionResponse target = null;
            target = (net.ofx.types.x2003.x04.CreditCardStatementTransactionResponse)get_store().add_element_user(CCSTMTTRNRS$0);
            return target;
        }
    }
    
    /**
     * Removes the ith "CCSTMTTRNRS" element
     */
    public void removeCCSTMTTRNRS(int i)
    {
        synchronized (monitor())
        {
            check_orphaned();
            get_store().remove_element(CCSTMTTRNRS$0, i);
        }
    }
    
    /**
     * Gets array of all "CCSTMTENDTRNRS" elements
     */
    public net.ofx.types.x2003.x04.CreditCardStatementEndTransactionResponse[] getCCSTMTENDTRNRSArray()
    {
        synchronized (monitor())
        {
            check_orphaned();
            java.util.List targetList = new java.util.ArrayList();
            get_store().find_all_element_users(CCSTMTENDTRNRS$2, targetList);
            net.ofx.types.x2003.x04.CreditCardStatementEndTransactionResponse[] result = new net.ofx.types.x2003.x04.CreditCardStatementEndTransactionResponse[targetList.size()];
            targetList.toArray(result);
            return result;
        }
    }
    
    /**
     * Gets ith "CCSTMTENDTRNRS" element
     */
    public net.ofx.types.x2003.x04.CreditCardStatementEndTransactionResponse getCCSTMTENDTRNRSArray(int i)
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.CreditCardStatementEndTransactionResponse target = null;
            target = (net.ofx.types.x2003.x04.CreditCardStatementEndTransactionResponse)get_store().find_element_user(CCSTMTENDTRNRS$2, i);
            if (target == null)
            {
                throw new IndexOutOfBoundsException();
            }
            return target;
        }
    }
    
    /**
     * Returns number of "CCSTMTENDTRNRS" element
     */
    public int sizeOfCCSTMTENDTRNRSArray()
    {
        synchronized (monitor())
        {
            check_orphaned();
            return get_store().count_elements(CCSTMTENDTRNRS$2);
        }
    }
    
    /**
     * Sets array of all "CCSTMTENDTRNRS" element
     */
    public void setCCSTMTENDTRNRSArray(net.ofx.types.x2003.x04.CreditCardStatementEndTransactionResponse[] ccstmtendtrnrsArray)
    {
        synchronized (monitor())
        {
            check_orphaned();
            arraySetterHelper(ccstmtendtrnrsArray, CCSTMTENDTRNRS$2);
        }
    }
    
    /**
     * Sets ith "CCSTMTENDTRNRS" element
     */
    public void setCCSTMTENDTRNRSArray(int i, net.ofx.types.x2003.x04.CreditCardStatementEndTransactionResponse ccstmtendtrnrs)
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.CreditCardStatementEndTransactionResponse target = null;
            target = (net.ofx.types.x2003.x04.CreditCardStatementEndTransactionResponse)get_store().find_element_user(CCSTMTENDTRNRS$2, i);
            if (target == null)
            {
                throw new IndexOutOfBoundsException();
            }
            target.set(ccstmtendtrnrs);
        }
    }
    
    /**
     * Inserts and returns a new empty value (as xml) as the ith "CCSTMTENDTRNRS" element
     */
    public net.ofx.types.x2003.x04.CreditCardStatementEndTransactionResponse insertNewCCSTMTENDTRNRS(int i)
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.CreditCardStatementEndTransactionResponse target = null;
            target = (net.ofx.types.x2003.x04.CreditCardStatementEndTransactionResponse)get_store().insert_element_user(CCSTMTENDTRNRS$2, i);
            return target;
        }
    }
    
    /**
     * Appends and returns a new empty value (as xml) as the last "CCSTMTENDTRNRS" element
     */
    public net.ofx.types.x2003.x04.CreditCardStatementEndTransactionResponse addNewCCSTMTENDTRNRS()
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.CreditCardStatementEndTransactionResponse target = null;
            target = (net.ofx.types.x2003.x04.CreditCardStatementEndTransactionResponse)get_store().add_element_user(CCSTMTENDTRNRS$2);
            return target;
        }
    }
    
    /**
     * Removes the ith "CCSTMTENDTRNRS" element
     */
    public void removeCCSTMTENDTRNRS(int i)
    {
        synchronized (monitor())
        {
            check_orphaned();
            get_store().remove_element(CCSTMTENDTRNRS$2, i);
        }
    }
}
